const express = require('express');
const router = express.Router()

// 导入用户处理函数模块
const user_handler = require('../router_handler/user')

// 导入验证数据的中间件
const expressJoi = require('@escook/express-joi')
const { scheme } = require('../schedule/index')

// 注册新用户
router.post('/reguser',expressJoi(scheme), user_handler.regUser)
// 登录
router.post('/login',expressJoi(scheme), user_handler.login)

module.exports = router